package com.tgy.esp32Service.exception;

/***
 * @ClassName: BasicErrorType
 * @Description: 常见异常
 * @Auther: tanggy3
 * @Date: 15:37 2022/9/14
 * @version : V1.0
 */
public class BasicErrorType {

    //系统异常 SE
    public static final BasicErrorType NULLPOINTER_SYSTEM_ERROR = new BasicErrorType("SE001", "空指针异常");
    public static final BasicErrorType METHOD_NOT_FOUND_ERROR = new BasicErrorType("SE002", "方法不存在");
    public static final BasicErrorType METHOD_NOT_SUPPORT_ERROR = new BasicErrorType("SE003", "请求方式不支持");
    public static final BasicErrorType REQUEST_PARAMETER_MISS_ERROR = new BasicErrorType("SE004", "请求参数缺失");
    public static final BasicErrorType MEDIA_TYPE_NOT_SUPPORT_ERROR = new BasicErrorType("SE005", "媒体类型不支持");
    public static final BasicErrorType UNKNOW_ERROR = new BasicErrorType("SE006", "未知错误");


    private String code;
    private String msg;

    public BasicErrorType(String code, String msg) {
        this.code = code;
        this.msg = msg;
    }

    public String getCode() {
        return code;
    }

    public void setCode(String code) {
        this.code = code;
    }

    public String getMsg() {
        return msg;
    }

    public void setMsg(String msg) {
        this.msg = msg;
    }
}
